﻿<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:dxwindow="clr-namespace:DevExpress.Internal.DXWindow;assembly=UColor.Core"
    xmlns:helpers="clr-namespace:UColor.Core.Helpers;assembly=UColor.Core"
    xmlns:demoparts="clr-namespace:UColor.Core.DemoParts;assembly=UColor.Core">

    <Style x:Key="OKButton" TargetType="Button">
        <Setter Property="Foreground" Value="White" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="Button">
                    <Grid Background="Transparent">
                        <Border x:Name="Background" BorderThickness="1" BorderBrush="White" />
                        <Border Padding="1">
                            <ContentPresenter Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" />
                        </Border>
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsMouseOver" Value="True">
                            <Setter TargetName="Background" Property="Background" Value="#FFA0A0A0" />
                        </Trigger>
                        <Trigger Property="IsPressed" Value="True">
                            <Setter TargetName="Background" Property="Background" Value="#FF909090" />
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
    <Style x:Key="CenterErrorMessage" TargetType="demoparts:CenterErrorMessage">
        <Setter Property="Width" Value="300" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="demoparts:CenterErrorMessage">
                    <Border x:Name="LayoutRoot" Background="#FFA50023" Padding="12">
                        <Grid>
                            <Grid.RowDefinitions>
                                <RowDefinition Height="*" />
                                <RowDefinition Height="Auto" />
                            </Grid.RowDefinitions>
                            <dxwindow:DocumentPresenter Background="Transparent" Foreground="White" Document="{TemplateBinding Message}" />
                            <StackPanel Grid.Row="1" Margin="0,12,0,0" HorizontalAlignment="Center" Orientation="Horizontal">
                                <Button x:Name="IgnoreButton" Style="{StaticResource OKButton}" Content="Ignore" Width="80" />
                                <Border Width="10" />
                                <Button x:Name="OKButton" Style="{StaticResource OKButton}" Content="OK" Width="80" />
                            </StackPanel>
                        </Grid>
                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
</ResourceDictionary>